#ifndef ACCOUNT_SYSTEM_CUSTOMER_H
#define ACCOUNT_SYSTEM_CUSTOMER_H

#include <string>
#include <memory>
#include <vector>
#include "SavingsAccount.h"
#include "CheckingAccount.h"
using namespace std;
class Customer
{
private:
    string name;                                  // 客户姓名
    shared_ptr<SavingsAccount> savingsAccount;    // 储蓄账户
    shared_ptr<CheckingAccount> checkingAccount;  // 支票账户

public:
    // 客户构造函数，初始化客户姓名、储蓄账户和支票账户
    Customer(const string &customerName,
             const shared_ptr<SavingsAccount> &savings,
             const shared_ptr<CheckingAccount> &checking);

    // 获取方法
    string getName() const;                           // 获取客户姓名
    shared_ptr<SavingsAccount> getSavingsAccount() const;    // 获取储蓄账户
    shared_ptr<CheckingAccount> getCheckingAccount() const;  // 获取支票账户

    // 实用方法
    vector<shared_ptr<Transaction>> getAllTransactions() const;  // 获取所有交易记录
    void generateCustomerReport(const string &filename) const;        // 生成客户报告
};

#endif // ACCOUNT_SYSTEM_CUSTOMER_H